var gulp = require('gulp'),
    less = require('gulp-less');

//基本使用
//gulp.task('testLess', function() {
//  gulp.src('src/less/index.less')
//    .pipe(plumber({errorHandler: notify.onError('Error: <%= error.message %>')}))
//    .pipe(less())
//    .pipe(gulp.dest('src/css'));
//});

//编译多个less文件
//gulp.task('testLess', function() {
//  gulp.src(['src/less/index.less', 'src/less/detail.less']) //多个文件数组形式
//      .pipe(less())
//      .pipe(gulp.dest('src/css'));
//
//});

//匹配符"!","*","**", "{}"
//gulp.task('testLess', function() {
//  gulp.src(['src/less/*.less', '!src/less/**/{reset,test}.less'])
//    .pipe(less())
//    .pipe(gulp.dest('src/css'));
//});

//匹配符"!","*","**", "{}"
gulp.task('testLess', function() {
  gulp.src('src/less/*.less')
    .pipe(less())
    .pipe(gulp.dest('src/css'));
});
console.log(123);

gulp.task('testWatch', function() {
  gulp.watch('src/**/*.less', ['testLess']);
});



gulp.task('default', ['testLess']);